/**
 * Copyright (c) 2016-2019 九点科技 All rights reserved.
 *
 * http://www.9dyun.cn
 *
 * 版权所有，侵权必究！
 */
package com.dian.api.inv.param;

import com.dian.common.validator.group.AddGroup;
import com.dian.common.validator.group.UpdateGroup;
import com.gitee.easyopen.doc.annotation.ApiDocField;
import lombok.Data;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.math.BigDecimal;

/**
 * 出库单明细
 *
 * @author xiaolai
 * @email xiaolai@9dyun.cn
 * @date 2019-06-11 00:16:18
 */
@Data
public class OutLineParam  {private static final long serialVersionUID = 1L;

    /**
     * 商品编码;来源于base_goods.goods_code
     */
    @ApiDocField(description = "仓库名称")
    @NotBlank(message="商品编码不能为空")
    @Length(max=40, message="商品编码长度不能超过40个字符")
    private String goodsCode;
    /**
     * 商品名称;来源于base_goods.name
     */
    @ApiDocField(description = "商品名称")
    @NotBlank(message="商品名称不能为空")
    @Length(max=200, message="商品名称长度不能超过200个字符")
    private String goodsName;
    /**
     * 商品型号;来源于base_goods.goods_model
     */
    @ApiDocField(description = "商品型号")
    @NotBlank(message="商品型号不能为空")
    @Length(max=100, message="商品型号长度不能超过100个字符")
    private String goodsModel;
    /**
     * 商品规格;来源于base_goods.goods_space
     */
    @ApiDocField(description = "商品规格")
    @NotBlank(message="商品规格不能为空",  groups ={AddGroup.class, UpdateGroup.class})
    @Length(max=100,  groups ={AddGroup.class, UpdateGroup.class}, message="商品规格长度不能超过100个字符")
    private String goodsSpec;
    /**
     * 基础数量
     */
    @ApiDocField(description = "订单数量/方", required = true)
    @NotNull(message="订单数量/方不能为空")
    private BigDecimal baseNum;

    /**
     * 库存数量
     */
    @ApiDocField(description = "订单数量/件", required = true)
    @NotNull(message="订单数量/件不能为空")
    private BigDecimal qtyNum;

    /**
     * 辅助数量
     */
    @ApiDocField(description = "订单数量/片", required = true)
    @NotNull(message="订单数量/片不能为空")
    private BigDecimal auxNum;

    /**
     * 件换算
     */
    @ApiDocField(description = "每件平方", required = true)
    private BigDecimal converUnit1;
    /**
     * 片换算
     */
    @ApiDocField(description = "每片平方")
    private BigDecimal converUnit2;

    /**
     * 包装码
     */
    @ApiDocField(description = "包装码")
    private String cfpackCode;
    /**
     * 缺陷
     */
    @ApiDocField(description = "缺陷")
    private  String fault;
    /**
     * 生产调度号schedule_no
     */
    @ApiDocField(description = "生产调度号")
    private  String scheduleNo;
    /**
     * 批次flot
     */
    @ApiDocField(description = "批次")
    private  String flot;
    /**
     * 尺寸item_size
     */
    @ApiDocField(description = "尺寸")
    private  String itemSize;
    /**
     * 外包装码名称boxing_name
     */
    @ApiDocField(description = "外包装码名称")
    private  String boxingName;
}
